﻿<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
    <title>方法内容编辑</title>
    <link rel="stylesheet" href="../../Scripts/codemirror/doc/docs.css" />
    <link rel="stylesheet" href="../../Scripts/codemirror/lib/codemirror.css" />
    <link rel="stylesheet" href="../../Scripts/codemirror/theme/eclipse.css" />
    <link rel="stylesheet" href="../../Scripts/codemirror/theme/elegant.css" />
    <link rel="stylesheet" href="../../Scripts/codemirror/theme/erlang-dark.css" />
    <link rel="stylesheet" href="../../Scripts/codemirror/theme/idea.css" />
    <script src="../../Scripts/codemirror/lib/codemirror.js" type="text/javascript"></script>
    <script src="../../Scripts/codemirror/mode/javascript/javascript.js" type="text/javascript"></script>
    <script src="../../Scripts/codemirror/addon/selection/active-line.js" type="text/javascript"></script>
    <script src="../../Scripts/codemirror/addon/edit/matchbrackets.js" type="text/javascript"></script>
    <link href="../../../DataUser/Style/ccbpm.css" rel="stylesheet" type="text/css" />
    <script type="text/javascript" src="../../Scripts/bootstrap/js/jquery.min.js"></script>
    <script src="../../Scripts/QueryString.js" type="text/javascript"></script>
    <script type="text/javascript" src="../../Scripts/config.js"></script>
    <script type="text/javascript" src="../../Comm/Gener.js"></script>
    <base target="_self" />
    <script type="text/javascript">
        function Esc() {
            if (event.keyCode == 27)
                window.close();
            return true;
        }

        function selectTheme() {
            var theme = input.options[input.selectedIndex].textContent;
            editor.setOption("theme", theme);
            location.hash = "#" + theme;
        }

        //页面启动函数.
        $(function () {

            var editor = CodeMirror.fromTextArea(document.getElementById("tb_doc"), {
                lineNumbers: true,
                styleActiveLine: true,
                matchBrackets: true,
                theme: "erlang-dark"
            });

            var input = document.getElementById("select");

            var handler = new HttpHandler("BP.CCBill.WF_CCBill");
            handler.AddUrlData();
            var data = handler.DoMethodReturnString("MethodDocDemoSQL_Init");

            editor.setValue(data);

        });
    </script>
</head>
<body onkeypress="Esc();" style="font-size: smaller">
    <table id="Table1" style="width: 100%; height: 100%;">
        <caption>
            方法内容编辑 demo - 你可以把这些内容copy到编辑器里面去. 更换主题：
            <select onchange="selectTheme()" id="select">
                <option selected="selected">eclipse</option>
                <option>elegant</option>
                <option>erlang-dark</option>
                <option>idea</option>
            </select>
        </caption>
        <tr>
            <td valign="top">
                <textarea id="tb_doc" style="width: 100%; height: 100%;" rows="60"></textarea>
            </td>
        </tr>
    </table>
</body>
</html>
